<template>
    <ul class="list-group">
        <li class="list-group-item"  style="background-image: linear-gradient(to top, #6a85b6 0%, #bac8e0 100%);;color: #fff;display: flex;font-size: 16px;">
        <div style="width: 6px ;height: 16px;background-image: linear-gradient(180deg, #2af598 0%, #009efd 100%);margin: 4px 2px"></div><strong>{{datalist.title}}</strong></li>
        <li class="list-group-item">
            <div class="form-check" v-for="(item,index) in datalist.sysAnswerList" :key="index" style="margin: 12px 0;font-size: 14px;">
                <input type="radio" :name="'radio'+datalist.questionId" class="form-check-input"  :value="item.answerId"  @click="test(item.answerId)">{{ item.answerContent}}
            </div>
        </li>
</ul>
</template>
<script>
	export default {
          name: 'RadioView',
          props:{
            datalist:Object,
            questionnaireId:0
          },
	data() {
		return {
		
		};
	},
    
  methods:{
    test(e){
    //  console.log('被选中的值为:'+e)
    let _a={'questionnaireId':this.questionnaireId,'questionId':this.datalist.questionId,'answerId':e}

      
    this.$emit('ontest', _a)
    }
  },
     
}                           
  </script>
<style>

</style>